<!DOCTYPE html>
<html lang="en"
      xmlns:th="http://www.thymeleaf.org"
      xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity5">

<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title>发改局</title>

  <!-- Google Font: Source Sans Pro -->
  <link rel="stylesheet"
        href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,400i,700&display=fallback">


  <!-- IonIcons -->
  <link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
  <!-- Theme style -->



  <link rel="stylesheet" href="../../plugins/fontawesome-free/css/all.css">
  <!-- Theme style -->
  <link rel="stylesheet" href="../../dist/css/adminlte.css">


  <!-- bootstrap-fileinput CSS -->
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.6.0/dist/css/bootstrap.min.css"
        crossorigin="anonymous">
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.5.0/font/bootstrap-icons.min.css"
        crossorigin="anonymous">

  <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css" crossorigin="anonymous">



  <link href="../../js/bootstrap-fileinput-5.2.2/css/fileinput.css" media="all" rel="stylesheet" type="text/css"/>
  <link href="../../js/bootstrap-fileinput-5.2.2/themes/explorer-fas/theme.css" media="all" rel="stylesheet"
        type="text/css"/>
</head>


<body class="hold-transition sidebar-mini">
<div class="wrapper">

  <!-- 主内容容器 -->
  <div class="content-wrapper">
    <!-- 容器头标题 -->
    <div class="content-header">
      <div class="container-fluid">

        <div class="row mb-2">
          <div class="col-sm-6">
            <h1 class="m-0">项目详情</h1>
          </div>
          <div class="col-sm-6">
            <ol class="breadcrumb float-sm-right">
              <li class="breadcrumb-item"><a href="#">首页</a></li>
              <li class="breadcrumb-item active">项目详情</li>
            </ol>
          </div>
        </div>

      </div>
    </div>

    <!-- 主题内容正文 -->
    <div class="content">
      <div class="container-fluid">
        <div class="row">
          <div class="col-lg-12">

            <div class="card card-primary">
              <!-- 卡片头部 -->
              <div class="card-header">
                <h3 class="card-title">项目详情</h3>
              </div>

              <!-- 表单开始 -->
              <form id="formData">
                <div class="card-body">
                  <div class="row">
                    <div class="col-lg-6">

                      <div class="form-group">
                        <label for="enId">企业名称</label>
                        <input type="text" class="form-control" id="enId" name="enId" th:value="${data.enName}" readonly />

                      </div>

                      <div class="form-group">
                        <label for="projectName">项目名称</label>
                        <input type="text" class="form-control" id="projectName"name="projectName" th:value="${data.projectName}" placeholder="项目名称" readonly>
                      </div>

                      <div class="form-group">
                        <label for="address">企业住所</label>
                        <input type="text" class="form-control" id="address" name="address" th:value="${data.address}" placeholder="企业住所" readonly>
                      </div>

                      <div class="form-group">
                        <label for="industry">所属行业</label>
                        <input type="text" class="form-control" id="industry" name="industry" th:value="${data.industry}" placeholder="所属行业" readonly>
                      </div>

                      <div class="form-group">
                        <label for="totalInvestment">总投资(万元)</label>
                        <input type="text" class="form-control" id="totalInvestment" name="totalInvestment" th:value="${data.totalInvestment}" placeholder="总投资" readonly>
                      </div>

                      <div class="form-group">
                        <label for="investmentCompleted">已完成投资(万元)</label>
                        <input type="text" class="form-control" id="investmentCompleted" name="investmentCompleted" th:value="${data.investmentCompleted}" placeholder="已完成投资" readonly>
                      </div>

                      <div class="form-group">
                        <label for="nextYearPlan">未来年计划(万元)</label>
                        <input type="text" class="form-control" id="nextYearPlan" name="nextYearPlan" th:value="${data.nextYearPlan}" placeholder="未来年计划" readonly>
                      </div>

                      <div class="form-check">
                        <input type="checkbox" class="form-check-input disabled" id="isScaleEnterprises" th:checked="${data.isScaleEnterprises}" name="isScaleEnterprises" readonly>
                        <label class="form-check-label" for="isScaleEnterprises">是否为规上企业</label>
                      </div>

                    </div>
                    <div class="col-lg-6">



                      <div class="form-group">
                        <label for="constructionContent">主要建设内容及规模</label>
                        <textarea class="form-control" id="constructionContent" name="constructionContent" th:text="${data.constructionContent}" placeholder="主要建设内容及规模" readonly></textarea>
                      </div>

                      <div class="form-group">
                        <label for="processDescription">主要工艺说明</label>
                        <textarea class="form-control" id="processDescription" name="processDescription" th:text="${data.processDescription}" placeholder="主要工艺说明" readonly></textarea>
                      </div>

                      <div class="form-group">
                        <label for="progressInfo">项目进展情况</label>
                        <textarea class="form-control" id="progressInfo" name="progressInfo" th:text="${data.progressInfo}" placeholder="项目进展情况" readonly></textarea>
                      </div>

                      <div class="form-group">
                        <label for="startTime">开工时间</label>
                        <input type="text" class="form-control" id="startTime" name="startTime" th:value="${#dates.format(data.startTime,'yyy-MM-dd')}" placeholder="开工时间" readonly />
                      </div>

                      <div class="form-group">
                        <label for="completedTime">计划建成投产时间</label>
                        <input type="text" class="form-control" id="completedTime" name="completedTime" th:value="${#dates.format(data.completedTime,'yyy-MM-dd')}" placeholder="计划建成投产时间" readonly />
                      </div>

                      <div class="form-group" th:if="${#httpSession.getAttribute('role_id') == 1}">
                        <label>企业关联用户</label>
                        <input type="text" class="form-control" id="userId" name="userId" th:value="${user.username}" readonly />

                      </div>

                    </div>
                  </div>

                  <hr/>


                  <div class="input-group">
                    <div class="row">
                      <div class="col-lg-12">
                        <div class="row">

                          <div class="col-lg-3" th:each="item:${bills}">
                            <!-- 营业执照图片                                         -->
                            <a th:href="${#httpServletRequest.getScheme() + '://' + #httpServletRequest.getServerName() + ':' + #request.getServerPort()+'/'+item.urlPath}" data-toggle="lightbox" data-title="图片预览">
                              <img th:src="${#httpServletRequest.getScheme() + '://' + #httpServletRequest.getServerName() + ':' + #request.getServerPort()+'/'+item.urlPath}" class="img-fluid mb-2" alt="营业执照"
                                   style="border: 1px solid black; padding: 10px; width: 450px;"/>
                            </a>
                          </div>

                        </div>
                      </div>
                    </div>
                  </div>

                </div>

                <!-- 保存按钮 -->
                <div class="card-footer">
                  <button type="button" class="btn btn-primary" id="pre_btn">返回上一页</button>
                </div>
              </form>

            </div>

          </div>

        </div>
      </div>
    </div>
  </div>

  <!-- Control Sidebar -->
<!--  <aside class="control-sidebar control-sidebar-dark">-->
<!--  </aside>-->

<!--  &lt;!&ndash; 版权信息 &ndash;&gt;-->
<!--  <footer class="main-footer">-->
<!--    <strong>Copyright &copy; 2021 <a href="http://www.chengzhouyun.com/" target="_blank">ChengZhouYun</a>.</strong> All-->
<!--    rights reserved.-->
<!--    <div class="float-right d-none d-sm-inline-block">-->
<!--      <b>Version</b> 1.0-->
<!--    </div>-->
<!--  </footer>-->

</div>

<!-- bootstrap-fileinput JS -->
<script src="https://code.jquery.com/jquery-3.5.1.min.js" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.6.0/dist/js/bootstrap.bundle.min.js"
        crossorigin="anonymous"></script>

<script src="../../plugins/jquery/jquery.js"></script>
<!-- Bootstrap -->
<script src="../../plugins/bootstrap/js/bootstrap.bundle.js"></script>
<!-- AdminLTE -->
<script src="../../dist/js/adminlte.js"></script>
<!-- OPTIONAL SCRIPTS -->
<!--<script src="../../plugins/chart.js/Chart.min.js"></script>-->
<!-- AdminLTE for demo purposes -->
<script src="../../dist/js/demo.js"></script>
<!-- AdminLTE dashboard demo (This is only for demo purposes) -->
<!--<script src="../dist/js/pages/dashboard3.js"></script>-->
<script src="../../js/bootstrap-fileinput-5.2.2/js/plugins/piexif.js" type="text/javascript"></script>
<script src="../../js/bootstrap-fileinput-5.2.2/js/plugins/sortable.js" type="text/javascript"></script>
<script src="../../js/bootstrap-fileinput-5.2.2/js/fileinput.js" type="text/javascript"></script>
<script src="../../js/bootstrap-fileinput-5.2.2/js/locales/zh.js" type="text/javascript"></script>
<script src="../../js/bootstrap-fileinput-5.2.2/themes/fas/theme.js" type="text/javascript"></script>
<script src="../../js/bootstrap-fileinput-5.2.2/themes/explorer-fas/theme.js" type="text/javascript"></script>
<script src="../../plugins/ekko-lightbox/ekko-lightbox.js" type="text/javascript"></script>

</body>

<script th:inline="javascript">

  $(document).ready(function () {

    // 返回上一页
    $("#pre_btn").on("click",function(event){
      window.history.back();
    })


    // 营业执照图片预览处理
    $(document).on('click', '[data-toggle="lightbox"]', function (event) {
      event.preventDefault();
      $(this).ekkoLightbox({
        alwaysShowClose: true
      });
    });


    $('.btn[data-filter]').on('click', function () {
      $('.btn[data-filter]').removeClass('active');
      $(this).addClass('active');
    });

  });
</script>
</html>
